<template>
    <z-block url="/do/list/process" :params="signParams">
        <template #default="sign">
            <el-tab-pane label="盖章记录" name="sign">
                <el-timeline style="max-width: 600px">
                    <el-timeline-item v-for="(pro, index) in sign" :key="index"
                                      :timestamp="new Date(pro.createGmt * 1000).toLocaleString()" placement="top"
                                      :color="(pro.status === 1 || pro.status == null) ? '#0bbd87' : '#FF0000'">
                        <z-avatar :value="pro.handler" :plain="false"/>
                        <div v-if="pro.status === 1">同意盖章</div>
                        <div v-if="pro.status === 0">拒绝盖章</div>
                        {{ pro.status === 0 ? "说明：" + pro.explain : "" }}

                    </el-timeline-item>
                </el-timeline>
            </el-tab-pane>
        </template>
    </z-block>
</template>

<script>


export default {
    props: {
        params: Object,
    },
    data() {
        return {
            signParams: null
        }
    },
    created() {
        this.signParams = {
            ...this.params,
            type: 2
        }
    }
}
</script>
